package com.naza.rpc.model;

import lombok.Data;

@Data
/**
 *  服务实例
 *  @author yl
 */
public class ServiceInstance {

    String id;

    String applicationName = "DEFAULT";

    String groupName;

    String serviceName;

    String ip;

    Integer port;

    String version;

    public ServiceInstance(){

    }

    public ServiceInstance(String id, String serviceName,String groupName, String ip, Integer port, String version) {
        this("DEFAULT", id, serviceName,groupName, ip, port, version);
    }

    public ServiceInstance(String id, String applicationName,String groupName, String serviceName, String ip, Integer port, String version) {
        this.id = id;
        this.applicationName = applicationName;
        this.groupName = groupName;
        this.serviceName = serviceName;
        this.ip = ip;
        this.port = port;
        this.version = version;
    }
}
